/**
 * Generate time : 2011-07-04 14:34:32
 * Version : 1.0.1.V20070717
 */
package com.baosight.sczx.zm.cm.domain;

import com.baosight.iplat4j.util.NumberUtils;
import com.baosight.iplat4j.core.ei.EiColumn;
import com.baosight.iplat4j.ep.DaoEPBase;
import java.util.HashMap;
import java.util.Map;
import com.baosight.iplat4j.util.StringUtils;

/**
 * ZMCMReceiveGoods
 * 
 */
public class ZMCMReceiveGoods extends DaoEPBase {

	private String fdKeyId = " "; /* 主键 */
	private String fdYear = " "; /* 年份 */
	private String fdMonth = " "; /* 月份 */
	private String fdDate = " "; /* 到货日期 */
	private String fdStatus = " "; /* 记录状态 */
	private String fdSupplyName = " "; /* 供应商名称 */
	private String fdDistribute = " "; /* 配拨单号 */
	private String fdReason = " "; /* 送货单号 */
	private Double fdSum = new Double(0); /* 单据金额 */
	private String fdValidator = " "; /* 验收人 */
	private String fdSupplyer = " "; /* 交货人 */
	private String fdRemark = " "; /* 备注 */
	private String fdPlanCode = " "; /* 计划编号 */
	private Long fdIsfromPlan = new Long(0); /* 是否来自采购计划 */
	private String fdDepotAdministrator = " "; /* 库管员ID */
	private String fdBuyer = " "; /* 采购员 */
	private String fdStorePlace = " "; /* 存放地点 */
	private Long fdNoImportCount = new Long(0); /* 未办理入库数量 */

	/**
	 * initialize the metadata
	 */
	public void initMetaData() {
		EiColumn eiColumn;

		eiColumn = new EiColumn("fdKeyId");
		eiColumn.setPrimaryKey(true);
		eiColumn.setFieldLength(32);
		eiColumn.setDescName("主键");
		eiMetadata.addMeta(eiColumn);

		eiColumn = new EiColumn("fdYear");
		eiColumn.setFieldLength(4);
		eiColumn.setDescName("年份");
		eiMetadata.addMeta(eiColumn);

		eiColumn = new EiColumn("fdMonth");
		eiColumn.setFieldLength(2);
		eiColumn.setDescName("月份");
		eiMetadata.addMeta(eiColumn);

		eiColumn = new EiColumn("fdDate");
		eiColumn.setFieldLength(10);
		eiColumn.setDescName("到货日期");
		eiMetadata.addMeta(eiColumn);

		eiColumn = new EiColumn("fdStatus");
		eiColumn.setFieldLength(10);
		eiColumn.setDescName("记录状态");
		eiMetadata.addMeta(eiColumn);

		eiColumn = new EiColumn("fdSupplyName");
		eiColumn.setFieldLength(200);
		eiColumn.setDescName("供应商名称");
		eiMetadata.addMeta(eiColumn);

		eiColumn = new EiColumn("fdDistribute");
		eiColumn.setFieldLength(80);
		eiColumn.setDescName("配拨单号");
		eiMetadata.addMeta(eiColumn);

		eiColumn = new EiColumn("fdReason");
		eiColumn.setFieldLength(80);
		eiColumn.setDescName("送货单号");
		eiMetadata.addMeta(eiColumn);

		eiColumn = new EiColumn("fdSum");
		eiColumn.setType("N");
		eiColumn.setScaleLength(5);
		eiColumn.setFieldLength(15);
		eiColumn.setDescName("单据金额");
		eiMetadata.addMeta(eiColumn);

		eiColumn = new EiColumn("fdValidator");
		eiColumn.setFieldLength(32);
		eiColumn.setDescName("验收人");
		eiMetadata.addMeta(eiColumn);

		eiColumn = new EiColumn("fdSupplyer");
		eiColumn.setFieldLength(32);
		eiColumn.setDescName("交货人");
		eiMetadata.addMeta(eiColumn);

		eiColumn = new EiColumn("fdRemark");
		eiColumn.setFieldLength(200);
		eiColumn.setDescName("备注");
		eiMetadata.addMeta(eiColumn);

		eiColumn = new EiColumn("fdPlanCode");
		eiColumn.setType("N");
		eiColumn.setDescName("计划编号");
		eiMetadata.addMeta(eiColumn);
		
		eiColumn = new EiColumn("fdIsfromPlan");
		eiColumn.setType("N");
		eiColumn.setFieldLength(15);
		eiColumn.setDescName("是否来自采购计划");
		eiMetadata.addMeta(eiColumn);

		eiColumn = new EiColumn("fdDepotAdministrator");
		eiColumn.setFieldLength(32);
		eiColumn.setDescName("库管员");
		eiMetadata.addMeta(eiColumn);

		eiColumn = new EiColumn("fdBuyer");
		eiColumn.setFieldLength(50);
		eiColumn.setDescName("采购员");
		eiMetadata.addMeta(eiColumn);

		eiColumn = new EiColumn("fdStorePlace");
		eiColumn.setFieldLength(2000);
		eiColumn.setDescName("存放地点");
		eiMetadata.addMeta(eiColumn);

		eiColumn = new EiColumn("fdNoImportCount");
		eiColumn.setType("N");
		eiColumn.setFieldLength(15);
		eiColumn.setDescName("未办理入库数量");
		eiMetadata.addMeta(eiColumn);
	}

	/**
	 * the constructor
	 */
	public ZMCMReceiveGoods() {
		initMetaData();
	}

	/**
	 * get the fdKeyId - 主键
	 * 
	 * @return the fdKeyId
	 */
	public String getFdKeyId() {
		return this.fdKeyId;
	}

	/**
	 * set the fdKeyId - 主键
	 */
	public void setFdKeyId(String fdKeyId) {
		this.fdKeyId = fdKeyId;
	}

	/**
	 * get the fdYear - 年份
	 * 
	 * @return the fdYear
	 */
	public String getFdYear() {
		return this.fdYear;
	}

	/**
	 * set the fdYear - 年份
	 */
	public void setFdYear(String fdYear) {
		this.fdYear = fdYear;
	}

	/**
	 * get the fdMonth - 月份
	 * 
	 * @return the fdMonth
	 */
	public String getFdMonth() {
		return this.fdMonth;
	}

	/**
	 * set the fdMonth - 月份
	 */
	public void setFdMonth(String fdMonth) {
		this.fdMonth = fdMonth;
	}

	/**
	 * get the fdDate - 到货日期
	 * 
	 * @return the fdDate
	 */
	public String getFdDate() {
		return this.fdDate;
	}

	/**
	 * set the fdDate - 到货日期
	 */
	public void setFdDate(String fdDate) {
		this.fdDate = fdDate;
	}

	/**
	 * get the fdStatus - 记录状态
	 * 
	 * @return the fdStatus
	 */
	public String getFdStatus() {
		return this.fdStatus;
	}

	/**
	 * set the fdStatus - 记录状态
	 */
	public void setFdStatus(String fdStatus) {
		this.fdStatus = fdStatus;
	}

	/**
	 * get the fdSupplyName - 供应商名称
	 * 
	 * @return the fdSupplyName
	 */
	public String getFdSupplyName() {
		return this.fdSupplyName;
	}

	/**
	 * set the fdSupplyName - 供应商名称
	 */
	public void setFdSupplyName(String fdSupplyName) {
		this.fdSupplyName = fdSupplyName;
	}

	/**
	 * get the fdDistribute - 配拨单号
	 * 
	 * @return the fdDistribute
	 */
	public String getFdDistribute() {
		return this.fdDistribute;
	}

	/**
	 * set the fdDistribute - 配拨单号
	 */
	public void setFdDistribute(String fdDistribute) {
		this.fdDistribute = fdDistribute;
	}

	/**
	 * get the fdReason - 送货单号
	 * 
	 * @return the fdReason
	 */
	public String getFdReason() {
		return this.fdReason;
	}

	/**
	 * set the fdReason - 送货单号
	 */
	public void setFdReason(String fdReason) {
		this.fdReason = fdReason;
	}

	/**
	 * get the fdSum - 单据金额
	 * 
	 * @return the fdSum
	 */
	public Double getFdSum() {
		return this.fdSum;
	}

	/**
	 * set the fdSum - 单据金额
	 */
	public void setFdSum(Double fdSum) {
		this.fdSum = fdSum;
	}

	/**
	 * get the fdValidator - 验收人
	 * 
	 * @return the fdValidator
	 */
	public String getFdValidator() {
		return this.fdValidator;
	}

	/**
	 * set the fdValidator - 验收人
	 */
	public void setFdValidator(String fdValidator) {
		this.fdValidator = fdValidator;
	}

	/**
	 * get the fdSupplyer - 交货人
	 * 
	 * @return the fdSupplyer
	 */
	public String getFdSupplyer() {
		return this.fdSupplyer;
	}

	/**
	 * set the fdSupplyer - 交货人
	 */
	public void setFdSupplyer(String fdSupplyer) {
		this.fdSupplyer = fdSupplyer;
	}

	/**
	 * get the fdRemark - 备注
	 * 
	 * @return the fdRemark
	 */
	public String getFdRemark() {
		return this.fdRemark;
	}

	/**
	 * set the fdRemark - 备注
	 */
	public void setFdRemark(String fdRemark) {
		this.fdRemark = fdRemark;
	}

	/**
	 * get the fdPlanCode - 计划编号
	 * 
	 * @return the fdPlanCode
	 */
	public String getFdPlanCode() {
		return this.fdPlanCode;
	}

	/**
	 * set the fdPlanCode - 计划编号
	 */
	public void setFdPlanCode(String fdPlanCode) {
		this.fdPlanCode = fdPlanCode;
	}
	
	/**
	 * get the fdIsfromPlan - 是否来自采购计划
	 * 
	 * @return the fdIsfromPlan
	 */
	public Long getFdIsfromPlan() {
		return this.fdIsfromPlan;
	}

	/**
	 * set the fdIsfromPlan - 计划编号
	 */
	public void setFdIsfromPlan(Long fdIsfromPlan) {
		this.fdIsfromPlan = fdIsfromPlan;
	}

	/**
	 * get the fdDepotAdministrator - 库管员
	 * 
	 * @return the fdDepotAdministrator
	 */
	public String getFdDepotAdministrator() {
		return this.fdDepotAdministrator;
	}

	/**
	 * set the fdDepotAdministrator - 库管员
	 */
	public void setFdDepotAdministrator(String fdDepotAdministrator) {
		this.fdDepotAdministrator = fdDepotAdministrator;
	}

	/**
	 * get the fdBuyer - 采购员
	 * 
	 * @return the fdBuyer
	 */
	public String getFdBuyer() {
		return this.fdBuyer;
	}

	/**
	 * set the fdBuyer - 采购员
	 */
	public void setFdBuyer(String fdBuyer) {
		this.fdBuyer = fdBuyer;
	}

	/**
	 * get the fdStorePlace - 存放地点
	 * 
	 * @return the fdStorePlace
	 */
	public String getFdStorePlace() {
		return this.fdStorePlace;
	}

	/**
	 * set the fdStorePlace - 存放地点
	 */
	public void setFdStorePlace(String fdStorePlace) {
		this.fdStorePlace = fdStorePlace;
	}

	/**
	 * get the fdNoImportCount - 未办理入库数量
	 * 
	 * @return the fdNoImportCount
	 */
	public Long getFdNoImportCount() {
		return this.fdNoImportCount;
	}

	/**
	 * set the fdNoImportCount - 未办理入库数量
	 */
	public void setFdNoImportCount(Long fdNoImportCount) {
		this.fdNoImportCount = fdNoImportCount;
	}

	/**
	 * get the value from Map
	 */
	@SuppressWarnings("rawtypes")
	public void fromMap(Map map) {

		setFdKeyId(StringUtils.defaultIfEmpty(StringUtils.toString(map.get("fdKeyId")), fdKeyId));
		setFdYear(StringUtils.defaultIfEmpty(StringUtils.toString(map.get("fdYear")), fdYear));
		setFdMonth(StringUtils.defaultIfEmpty(StringUtils.toString(map.get("fdMonth")), fdMonth));
		setFdDate(StringUtils.defaultIfEmpty(StringUtils.toString(map.get("fdDate")), fdDate));
		setFdStatus(StringUtils.defaultIfEmpty(StringUtils.toString(map.get("fdStatus")), fdStatus));
		setFdSupplyName(StringUtils.defaultIfEmpty(StringUtils.toString(map.get("fdSupplyName")), fdSupplyName));
		setFdDistribute(StringUtils.defaultIfEmpty(StringUtils.toString(map.get("fdDistribute")), fdDistribute));
		setFdReason(StringUtils.defaultIfEmpty(StringUtils.toString(map.get("fdReason")), fdReason));
		setFdSum(NumberUtils.toDouble(StringUtils.toString(map.get("fdSum")), fdSum));
		setFdValidator(StringUtils.defaultIfEmpty(StringUtils.toString(map.get("fdValidator")), fdValidator));
		setFdSupplyer(StringUtils.defaultIfEmpty(StringUtils.toString(map.get("fdSupplyer")), fdSupplyer));
		setFdRemark(StringUtils.defaultIfEmpty(StringUtils.toString(map.get("fdRemark")), fdRemark));
		setFdPlanCode(StringUtils.defaultIfEmpty(StringUtils.toString(map.get("fdPlanCode")), fdPlanCode));
		setFdIsfromPlan(NumberUtils.toLong(StringUtils.toString(map.get("fdIsfromPlan")), fdIsfromPlan));
		setFdDepotAdministrator(StringUtils.defaultIfEmpty(StringUtils.toString(map.get("fdDepotAdministrator")), fdDepotAdministrator));
		setFdBuyer(StringUtils.defaultIfEmpty(StringUtils.toString(map.get("fdBuyer")), fdBuyer));
		setFdStorePlace(StringUtils.defaultIfEmpty(StringUtils.toString(map.get("fdStorePlace")), fdStorePlace));
		setFdNoImportCount(NumberUtils.toLong(StringUtils.toString(map.get("fdNoImportCount")), fdNoImportCount));
	}

	/**
	 * set the value to Map
	 */
	@SuppressWarnings({ "rawtypes", "unchecked" })
	public Map toMap() {

		Map map = new HashMap();
		map.put("fdKeyId", StringUtils.toString(fdKeyId, eiMetadata.getMeta("fdKeyId")));
		map.put("fdYear", StringUtils.toString(fdYear, eiMetadata.getMeta("fdYear")));
		map.put("fdMonth", StringUtils.toString(fdMonth, eiMetadata.getMeta("fdMonth")));
		map.put("fdDate", StringUtils.toString(fdDate, eiMetadata.getMeta("fdDate")));
		map.put("fdStatus", StringUtils.toString(fdStatus, eiMetadata.getMeta("fdStatus")));
		map.put("fdSupplyName", StringUtils.toString(fdSupplyName, eiMetadata.getMeta("fdSupplyName")));
		map.put("fdDistribute", StringUtils.toString(fdDistribute, eiMetadata.getMeta("fdDistribute")));
		map.put("fdReason", StringUtils.toString(fdReason, eiMetadata.getMeta("fdReason")));
		map.put("fdSum", StringUtils.toString(fdSum, eiMetadata.getMeta("fdSum")));
		map.put("fdValidator", StringUtils.toString(fdValidator, eiMetadata.getMeta("fdValidator")));
		map.put("fdSupplyer", StringUtils.toString(fdSupplyer, eiMetadata.getMeta("fdSupplyer")));
		map.put("fdRemark", StringUtils.toString(fdRemark, eiMetadata.getMeta("fdRemark")));
		map.put("fdPlanCode", StringUtils.toString(fdPlanCode, eiMetadata.getMeta("fdPlanCode")));
		map.put("fdIsfromPlan", StringUtils.toString(fdIsfromPlan, eiMetadata.getMeta("fdIsfromPlan")));
		map.put("fdDepotAdministrator", StringUtils.toString(fdDepotAdministrator, eiMetadata.getMeta("fdDepotAdministrator")));
		map.put("fdBuyer", StringUtils.toString(fdBuyer, eiMetadata.getMeta("fdBuyer")));
		map.put("fdStorePlace", StringUtils.toString(fdStorePlace, eiMetadata.getMeta("fdStorePlace")));
		map.put("fdNoImportCount", StringUtils.toString(fdNoImportCount, eiMetadata.getMeta("fdNoImportCount")));

		return map;

	}
}